
************************************************************************************************************
**#							TABLE 7 - LABOR EXPENSE DISCLOSERS
************************************************************************************************************

capture cd "/Users/joshw/CEO Pay Ratio/Analysis/"
use "Data/Temp/dataset_main.dta", clear

************************************************
*Labor Expense Interactions
************************************************

g interact_q5  = labor_exp*pr_quint_5
	la var interact_q5 "Labor expense discloser times quintile 5"
g interact_q1  = labor_exp*pr_quint_1
	la var interact_q5 "Labor expense discloser times quintile 1"
g interact_epr  = labor_exp*ln_epr
	la var interact_epr "Labor expense discloser times log of expected pay ratio"
g interact_upr  = labor_exp*ln_upr
	la var interact_upr "Labor expense discloser times log of unexpected pay ratio"
	
g interact2 = labor_exp * size
g interact3 = labor_exp * union
g interact4 = labor_exp * mtb
g interact5 = labor_exp * roa
g interact6 = labor_exp * io
g interact7 = labor_exp * rd
g interact8 = labor_exp * cash
g interact9 = labor_exp * lev
g interact10 = labor_exp * salesg_w
g interact11 = labor_exp * tsr
g interact12 = labor_exp * gd_pay_pre_365
g interact13 = labor_exp * fixed_assets
g interact14 = labor_exp * ln_prod_pre_365
g interact15 = labor_exp * gd_ceodis_pre_365


************************************************
************************************************
*PANEL A - CONTRAST
************************************************
************************************************

*************************
*Pay rating
*************************
est clear
eststo: xi: reghdfe gd_pay_diff_365 interact_q5 pr_quint_5 interact_q1 pr_quint_1 gd_pay_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact12 if sample_yr==1, noabsorb
eststo: xi: reghdfe gd_pay_diff_365 interact_q5 pr_quint_5 interact_q1 pr_quint_1 gd_pay_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact12 if sample_yr==1, absorb(ffi49) 

*************************
*Productivity
*************************
eststo: xi: reghdfe ln_prod_diff interact_q5 pr_quint_5 interact_q1 pr_quint_1 ln_prod_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd fixed_assets interact2-interact11 interact13 interact14 if sample_yr==1, noabsorb
eststo: xi: reghdfe ln_prod_diff interact_q5 pr_quint_5 interact_q1 pr_quint_1 ln_prod_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd fixed_assets interact2-interact11 interact13 interact14 if sample_yr==1, absorb(ffi49) 

*************************
*CEO Disapproval
*************************
eststo: xi: reghdfe gd_ceodis_diff_365 interact_q5 pr_quint_5 interact_q1 pr_quint_1 gd_ceodis_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact15 if sample_yr==1, noabsorb
eststo: xi: reghdfe gd_ceodis_diff_365 interact_q5 pr_quint_5 interact_q1 pr_quint_1 gd_ceodis_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact15 if sample_yr==1, absorb(ffi49) 

esttab using "Output/Tables/RF/T7_emp_laborexp_contrast.csv", b(3) ar2 title("Contrast employees labor expense") varwidth(25) order(interact_q5 interact_q1 labor_exp pr_quint_5 pr_quint_1 gd_pay_pre_365 ln_prod_pre_365 gd_ceodis_pre_365) star(* 0.10 ** 0.05  *** 0.01 ) replace

************************************************
************************************************
*PANEL B - SURPRISE
************************************************
************************************************	
	
*************************
*Pay rating
*************************
est clear
eststo: xi: reghdfe gd_pay_diff_365 interact_upr ln_upr interact_epr ln_epr gd_pay_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact12 if sample_yr==1, noabsorb
eststo: xi: reghdfe gd_pay_diff_365 interact_upr ln_upr interact_epr ln_epr gd_pay_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact12 if sample_yr==1, absorb(ffi49) 

*************************
*Productivity
*************************
eststo: xi: reghdfe ln_prod_diff interact_upr ln_upr interact_epr ln_epr ln_prod_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd fixed_assets interact2-interact11 interact13 interact14 if sample_yr==1, noabsorb
eststo: xi: reghdfe ln_prod_diff interact_upr ln_upr interact_epr ln_epr ln_prod_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd fixed_assets interact2-interact11 interact13 interact14 if sample_yr==1, absorb(ffi49) 

*************************
*CEO Disapproval
*************************
eststo: xi: reghdfe gd_ceodis_diff_365 interact_upr ln_upr interact_epr ln_epr gd_ceodis_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact15 if sample_yr==1, noabsorb
eststo: xi: reghdfe gd_ceodis_diff_365 interact_upr ln_upr interact_epr ln_epr gd_ceodis_pre_365 labor_exp size mtb roa io cash lev salesg_w tsr union rd interact2-interact11 interact15 if sample_yr==1, absorb(ffi49) 

esttab using "Output/Tables/RF/T7_emp_laborexp_surprise.csv", b(3) ar2 title("Surprise employees labor expense") varwidth(25) order(interact_upr interact_epr labor_exp ln_upr ln_epr gd_pay_pre_365 ln_prod_pre_365 gd_ceodis_pre_365) star(* 0.10 ** 0.05  *** 0.01 ) replace
